/**
 * 
 */
package niuke.练习赛15;

import java.util.Scanner;

/**
 * @author zhong
 *
 */
public class 吉姆的运算式 {

	/**
	 * @param args
	 */
	public static void main(String[] args) {
		Scanner scanner = new Scanner(System.in);
		String string = scanner.nextLine();
		scanner.close();
		String[] strings = string.split(",|\\(|\\)");// (|)|
		System.out.println((strings[strings.length - 1]));
	}

}
